﻿angular.module('Stackoverflow').controller('QuestionItemController', function ($scope, Restangular, ngTableParams, $stateParams, $location) {
    'use strict';
    $scope.model = {
        title: 'Title',
        content: 'Content'
    };

    $scope.save = function (model) {
        return Restangular.all('question').post(model).then(function (id) {
            $state.go('questions');
        });
    };
});